package com.bangcommunity.bbframe.sdm.domain;

import com.bangcommunity.bbframe.common.base.PageInfo;

import lombok.Data;

/**
 * Created by tanghc on 17/1/18.
 */
@Data
public class PageParam implements IPageParam {

    private static final long serialVersionUID = -1814386602814823064L;
    private Integer pageNo;
    private Integer pageSize;

    @Override
    public PageInfo getPageInfo() {
//        if (pageNo == null || pageNo < 1) {
//            pageNo = 1;
//        }
//        if (null == pageSize || pageSize < 1) {
//            pageSize = 10;
//        }
        return PageInfo.fromPageAndSize(pageNo, pageSize);
    }
}
